package com.ruoyi.web.service.impl;

import java.util.List;
import com.ruoyi.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.web.mapper.GuMrGuDapanMapper;
import com.ruoyi.web.domain.GuMrGuDapan;
import com.ruoyi.web.service.IGuMrGuDapanService;

/**
 * 大盘指数列Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-10-25
 */
@Service
public class GuMrGuDapanServiceImpl implements IGuMrGuDapanService 
{
    @Autowired
    private GuMrGuDapanMapper guMrGuDapanMapper;

    /**
     * 查询大盘指数列
     * 
     * @param id 大盘指数列主键
     * @return 大盘指数列
     */
    @Override
    public GuMrGuDapan selectGuMrGuDapanById(String id)
    {
        return guMrGuDapanMapper.selectGuMrGuDapanById(id);
    }

    /**
     * 查询大盘指数列列表
     * 
     * @param guMrGuDapan 大盘指数列
     * @return 大盘指数列
     */
    @Override
    public List<GuMrGuDapan> selectGuMrGuDapanList(GuMrGuDapan guMrGuDapan)
    {
        return guMrGuDapanMapper.selectGuMrGuDapanList(guMrGuDapan);
    }

    /**
     * 新增大盘指数列
     * 
     * @param guMrGuDapan 大盘指数列
     * @return 结果
     */
    @Override
    public int insertGuMrGuDapan(GuMrGuDapan guMrGuDapan)
    {
        guMrGuDapan.setCreateTime(DateUtils.getNowDate());
        return guMrGuDapanMapper.insertGuMrGuDapan(guMrGuDapan);
    }

    /**
     * 修改大盘指数列
     * 
     * @param guMrGuDapan 大盘指数列
     * @return 结果
     */
    @Override
    public int updateGuMrGuDapan(GuMrGuDapan guMrGuDapan)
    {
        guMrGuDapan.setUpdateTime(DateUtils.getNowDate());
        return guMrGuDapanMapper.updateGuMrGuDapan(guMrGuDapan);
    }

    /**
     * 批量删除大盘指数列
     * 
     * @param ids 需要删除的大盘指数列主键
     * @return 结果
     */
    @Override
    public int deleteGuMrGuDapanByIds(String[] ids)
    {
        return guMrGuDapanMapper.deleteGuMrGuDapanByIds(ids);
    }

    /**
     * 删除大盘指数列信息
     * 
     * @param id 大盘指数列主键
     * @return 结果
     */
    @Override
    public int deleteGuMrGuDapanById(String id)
    {
        return guMrGuDapanMapper.deleteGuMrGuDapanById(id);
    }
}
